home *** CD-ROM | disk | FTP | other *** search
/ CD ROM Paradise Collection 4 / CD ROM Paradise Collection 4 1995 Nov.iso / program / swags_z.zip / TIMING.SWG / 0002_TCTIMER.PAS.pas < prev    next >
Pascal/Delphi Source File  |  1993-05-28  |  408b  |  31 lines

  1. Unit tctimer;
  2.  
  3. Interface
  4. Uses tptimer;
  5.  
  6.   Var
  7.     start : LongInt;
  8.  
  9. Procedure StartTimer;
  10.  
  11. Procedure WriteElapsedTime;
  12.  
  13.  
  14.  
  15. Implementation
  16.  
  17. Procedure StartTimer;
  18.   begin
  19.     start := ReadTimer;
  20.   end;
  21.  
  22. Procedure  WriteElapsedTime;
  23.   Var stop : LongInt;
  24.   begin
  25.     stop := ReadTimer;
  26.     Writeln('Elapsed time = ',(ElapsedTime(start,stop) / 1000):10:6,' seconds');
  27.   end;
  28.  
  29.  
  30. end.
  31.